package com.yq.backend.controller;

import com.yq.backend.dto.CardDto;
import com.yq.backend.pojo.Result;
import com.yq.backend.service.InfoManageService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @descriptions: 信息管理
 * @author: yunqiang
 * @date: 2022/5/3 11:27
 */
@Api(tags = {"信息管理：信息管理控制类"})
@RestController
@RequestMapping("/api/v1/infoManage")
public class InfoManageController {



    @Autowired
    private InfoManageService infoManageService;
    @ApiOperation(value = "中奖统计")
    @PostMapping("/ winningStatistics")
    public Result winningStatistics(@RequestBody CardDto cardDto) { return this.infoManageService.winningStatistics(cardDto); }


    @ApiOperation(value = "中奖列表")
    @PostMapping("/ winningList")
    public Result winningList(@RequestBody CardDto cardDto) { return this.infoManageService.winningList(cardDto); }
}
